Computing and other systems often use multiple clock signals to perform various functions. For example, different buses may transport data between components of a computer system. These buses often operate at different speeds and use different clock signals. In these systems, components that use a common clock signal may form a “clock domain.” A queue is typically used to facilitate communication across the boundary between two clock domains. For example, data from one clock domain may be written into the queue, and the data is read from the queue by another clock domain.
A problem with conventional computer systems is that the size of the queue is often difficult to manage. As an example, some synchronization techniques require that the number of entries in some queues equals a power of two (2N). Because of this, it is often difficult to increase the size of the queue without wasting space. As a particular example, if the size of a queue needs to be increased by twenty percent, the number of entries in the queue would typically be doubled, resulting in much wasted space. Other techniques use a ring counter to manage a queue, but this makes it difficult to test the fullness of the queue and to determine if an arbitrary location in the queue is occupied.